//导入封装好的service
import service from '../util/request'

//导出接口
//店铺首页
export function shop_list(payload) {
    return service.get('/api/shop/list', { params: payload })
}
//爆爆团
export function tuan_list(shuju) {
    return service.get('/api/tuan/list', { params: shuju })
}
//店铺详情
export function shop_info(shuju) {
    return service.get('/api/shop/shopinfo', { params: shuju })
}
//轮播图
export function swiper_list(payload) {
    return service.get('/api/banner/list', { params: payload })
}
//购物车
export function shopcart_list(shuju) {
    return service.get('/api/shopcart/list', { params: shuju })
}

//注册
export function register_list(obj = {}) {
    return service.post('/api/user/register', obj)
}
//登录
export function login_list(obj = {}) {
    return service.post('/api/user/login', obj)
}
//店铺收藏
export function shop_fav(obj = {}) {
    return service.get('/api/shop/favlist', { params: obj })
}
//取消店铺收藏
export function shop_unfav(obj = {}) {
    return service.post('/api/shop/unfav', obj)
}
//收藏列表
export function shop_favlist(obj = {}) {
    return service.get('/api/shop/favlist', { params: obj })
}
//地址列表
export function address_list(obj = {}) {
    return service.get('/api/address/list', { params: obj })
}
//新增地址
export function address_add(obj = {}) {
    return service.post('/api/address/add', obj)
}


